Inside Macintosh: Imaging with QuickDraw

Previous | Chapter Top | Chapter Contents | Next

Graphics Devices Reference

This section describes the GDevice record, the routines that manipulate GDevice records, and the 'scrn' resource.

"Data Structures" shows the Pascal data structure for the GDevice record, which contains information about a video device or offscreen graphics world. "Data Structures" also shows the data structure for the DeviceLoopFlags data type, which defines a set of options you can specify to the DeviceLoop procedure.

"Routines for Graphics Devices" describes routines for creating, setting, and disposing of GDevice records; getting the available graphics devices; and determining device characteristics. Your application generally never needs to create, set, or dispose of GDevice records. However, you may find it useful for your application to get GDevice records to determine the capabilities of the user's screens. When zooming a window, for example, your application can use GDevice records to determine which screen contains the largest area of a window, and then determine the ideal window size for that screen. You may also wish to use the DeviceLoop procedure, described in this chapter, if you want to optimize your application's drawing for graphics devices with different capabilities. "Application-Defined Routine" describes how you can define your own drawing procedure when optimizing your application's drawing for different graphics devices.

"Resource" describes the screen ( 'scrn' ) resource. System software automatically creates and uses this resource; your application never needs it. The screen resource is documented here for your general information.

Data Structures

Routines for Graphics Devices

Creating, Setting, and Disposing of GDevice Records

Getting the Available Graphics Devices

Determining the Characteristics of a Video Device

Changing the Pixel Depth for a Video Device

Application-Defined Routine

Resource

The Screen Resource


© 1997 Apple Computer, Inc.

Previous | Chapter Top | Chapter Contents | Next